Use optional values for docker memory metrics#41449
Merged
fearful-symmetry merged 5 commits intoelastic:mainfrom Nov 1, 2024
Merged
Use optional values for docker memory metrics#41449fearful-symmetry merged 5 commits intoelastic:mainfrom
fearful-symmetry merged 5 commits intoelastic:mainfrom
Conversation
Contributor
|
Pinging @elastic/security-external-integrations (Team:Security-External Integrations) |
Contributor
|
This pull request does not have a backport label.
To fixup this pull request, you need to add the backport labels for the needed
|
Contributor
|
|
Contributor
|
Pinging @elastic/elastic-agent-data-plane (Team:Elastic-Agent-Data-Plane) |
mauri870
reviewed
Oct 25, 2024
mauri870
reviewed
Oct 25, 2024
rdner
approved these changes
Nov 1, 2024
mergify bot
pushed a commit
that referenced
this pull request
Nov 1, 2024
* use opt values for docker memory metrics * fix vars, comments * add changelog * spelling (cherry picked from commit 249d0dc)
6 tasks
pierrehilbert
added a commit
that referenced
this pull request
Nov 25, 2024
* use opt values for docker memory metrics * fix vars, comments * add changelog * spelling (cherry picked from commit 249d0dc) Co-authored-by: Alex K. <8418476+fearful-symmetry@users.noreply.github.com> Co-authored-by: Pierre HILBERT <pierre.hilbert@elastic.co>
Contributor
|
@fearful-symmetry Do we need this bug fix in 8.17? |
Contributor
Author
|
@pierrehilbert It's not really a "fix" as much as a clean-up, so I wouldn't say it's necessary. |
Closed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Proposed commit message
Closes #40060
This deals with an issue where we were reporting docker memory
rssmetrics even though none exist under cgroups V2. This takes the easy way out by just changing the hashmaps to use option types, so we don't report0values when none should exist.I'm not sure there's a better way to do this. As far as I can tell, there's no similar metrics in Docker's cgroups V2 reporting, and in my experience trying to be clever and derive a substitute value usually backfires for heterogeneous monitoring setups.
Checklist
CHANGELOG.next.asciidocorCHANGELOG-developer.next.asciidoc.Disruptive User Impact
In cases where the docker/memory metrics were reporting an invalid
0, they will not not report any value at all.